/*
 * @Author: your name
 * @Date: 2022-04-25 08:28:21
 * @LastEditTime: 2022-04-25 08:46:51
 * @LastEditors: Please set LastEditors
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 * @FilePath: \trace-source-web\src\api\production-api\Information-classification-and-traceability.js
 */

import xjaxios from "@/api/axios";
export default {
  /**
     * @description: 获取角色所拥有的功能权限
     * @param {String} userId
     * @param {String} system
     * @return {Object}
     */
  //  生长记录图片
  queryReportForm(params) {
    return xjaxios.post("v3/trace/growthRecord/queryGrowthRecordPage", params);
  },
  //  农资统计
  agriculturalInputsList(params) {
    return xjaxios.post("v3/trace/agriculturalInputs/queryPageList", params);
  },
  // 病虫害信息
  queryDataByBatchFrom(params) {
    return xjaxios.post("v3/trace/feignInfo/queryDataByBatchId", params);
  },
  // 农资统计
  agriculturalInputs(params) {
    return xjaxios.post("v3/trace/agriculturalInputs/queryByCondition", params);
  },

  // 获取生长环境数据ucharts图
  growthRecord(nowbatchNo) {
    return xjaxios.get(`v3/trace/growthRecord/getDataByBatchNo?batchNo=${nowbatchNo}`);
  },
  // 农事作业追溯
  farmingOperation(nowbatchNo) {
    return xjaxios.get(`v3/trace/farmingOperation/queryByBatchId?batchNo=${nowbatchNo}`);
  },
  // 病虫害发生次数
  feignInfo(nowbatchNo) {
    return xjaxios.get(`v3/insectSituation/insectCollection/getData?batchNo=${nowbatchNo}`);
  },
  // 病虫害发生次数uchart
  insectAlarm(nowbatchNo) {
    return xjaxios.get(`v3/patrol/insectAlarm/gatReport?batchNo=${nowbatchNo}`);
  }
}
